package com.hwadee.teachingprocessmanagementsystem.dto.teacher;

import lombok.Data;

import java.util.ArrayList;
import java.util.List;

/**
 * @author LINKE
 * @ProjectName:teaching-process-management-system-back
 * @Title: TeacherDataStatisticsDto
 * @Package com.hwadee.teachingprocessmanagementsystem.dto.teacher
 * @Description: 教师考试数据统计dto
 * @date 2024/7/17 14:24
 */

@Data
public class TeacherDataStatisticsDto {
    List<TeacherDataStatistics> teacherDataStatisticsList;


    public void addTeacherDataStatistics(TeacherDataStatistics teacherDataStatistics) {
        if (this.teacherDataStatisticsList == null) {
            this.teacherDataStatisticsList = new ArrayList<TeacherDataStatistics>();
        }
        this.teacherDataStatisticsList.add(teacherDataStatistics);
    }

    public void addTeacherDataStatistics(String studentNumber, String studentName, String type, String courseName, Integer grade) {
        TeacherDataStatistics teacherDataStatistics = new TeacherDataStatistics();
        teacherDataStatistics.setStudentNumber(studentNumber);
        teacherDataStatistics.setStudentName(studentName);
        teacherDataStatistics.setType(type);
        teacherDataStatistics.setCourseName(courseName);
        teacherDataStatistics.setGrade(grade);
        this.addTeacherDataStatistics(teacherDataStatistics);
    }

    public TeacherCourseStandardDto getTeacherCourseStandardDto() {
        return new TeacherCourseStandardDto();
    }

}

@Data
class TeacherDataStatistics {
    //学生id
    private String studentNumber;
    //学生姓名
    private String studentName;
    //课程类别
    private String type;
    //课程名称
    private String courseName;
    //考试成绩
    private Integer grade;
}
